USD_VS_RMB = 6.77
def 美元转人民币():
    mr = input("继续执行程序是/否:")
    if mr == "否":
        print("结束")
    elif mr == "是":
        currency_str_value = input("输入带单位的货币(CNY/USD):")
        unit = currency_str_value[-3:]
        if unit == "CNY":
            RMB = currency_str_value[:-3]
            rmb = eval(RMB)
            us = rmb / USD_VS_RMB
            print("美元金额: {:.2f}".format(us))
            # print("美元金额：",us)
        elif unit == "USD":
            US = currency_str_value[:-3]
            us = eval(US)
            rmb = us * USD_VS_RMB
            print("人民币:", rmb)
        else:
            print("无效")
        return 美元转人民币()
美元转人民币()